package cn.suxiaoxiang.mmskillbar.utils;

import io.lumine.xikage.mythicmobs.io.MythicConfig;
import io.lumine.xikage.mythicmobs.skills.Skill;
import org.bukkit.Bukkit;

/**
 * @author Corder-Suxiaoxiang
 * @UserName 程序员_Suxiaoxiang
 * @date 2025/1/24 16:58
 * @Version 1.0
 */
public class getConfigSkill {
    /**
     * 获取技能
     *
     * @return String
     * @Username 程序员-Su_xiaoxiang
     * @date 2025/1/24 16:59
     */
    public String getconfigskill(MythicConfig config){
         String skillList =   config.getString("Skills");
         if (skillList != null && !skillList.isEmpty()){
             if (skillList.contains("s=")){
                // Bukkit.getServer().getConsoleSender().sendMessage(skillList.replaceAll(".*s=([\\w\\u4e00-\\u9fa5]+).*", "$1"));
                 return skillList.replaceAll(".*s=([\\w\\u4e00-\\u9fa5]+).*", "$1");
             }
         }
         return null;
    }

}
